package com.glsc.ngateway.common.base.domainmapper.cmdb;
import com.glsc.ngateway.common.base.domain.mysql.cmdb.CmdbMemoryDetail;
import com.glsc.ngateway.common.base.domain.mysql.gateway.platform.flow.cmdb.FlowFormMemoryOutDetail;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @Author: zhengyr
 * @Desc: 配件入库流程表到业务表转换
 */
@Mapper(componentModel = "spring")
public interface FlowFormMemoryOutMapper {

    FlowFormMemoryOutMapper INSTANCE = Mappers.getMapper(FlowFormMemoryOutMapper.class);

    @Mapping(target = "memoryDetailId", ignore = true)
    @Mapping(target = "memoryDetailCode", ignore = true)
    @Mapping(target = "deviceCode", ignore = true)
    @Mapping(target = "isDelete", ignore = true)
    @Mapping(target = "locationId", ignore = true)
    @Mapping(target = "cmdbMemoryStandard", ignore = true)
    CmdbMemoryDetail dto2domain(FlowFormMemoryOutDetail dto);
    List<CmdbMemoryDetail> dto2domain(List<FlowFormMemoryOutDetail> dto);
}
